package com.rightsidetech.mall.mapper;

import com.rightsidetech.mall.dto.request.gift.GiftPageReq;
import com.rightsidetech.mall.dto.response.gift.ActGiftCommodityResp;
import com.rightsidetech.mall.dto.response.gift.GiftDetailResp;
import com.rightsidetech.mall.dto.response.gift.GiftPageResp;
import com.rightsidetech.mall.entity.MallGiftCommodity;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface MallGiftCommodityMapper {
    int deleteByPrimaryKey(Long id);

    int insert(MallGiftCommodity record);

    int insertSelective(MallGiftCommodity record);

    MallGiftCommodity selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(MallGiftCommodity record);

    int updateByPrimaryKey(MallGiftCommodity record);

    Long selectCountByInfoIdAndSpecs(@Param("baseInfoId") Long baseInfoId,@Param("specs") String specs);

    List<String> selectByBaseInfoId(Map<String, Object> map);

    List<GiftPageResp> selectPageList(GiftPageReq req);

    GiftDetailResp selectDetail(Long id);

    ActGiftCommodityResp selectActGiftById(Long id);

    List<MallGiftCommodity> selectByPrimaryKeyList(List<Long> list);
}